<?xml version="1.0" encoding="UTF-8" ?>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>

<h3><fmt:message key="administrator.all.heading"/></h3>

<table class="borderedlist">
	<tr>
		<th><fmt:message key="administrator.name"/></th>
		<th><fmt:message key="administrator.username"/></th>
		<th><fmt:message key="administrator.enabled"/></th>
		<th>&nbsp;</th>
	<c:forEach items="${model.administrators}" var="administrator">
	<tr>
		<td><c:out value="${administrator.name}"/></td>
		<td><a href="administrator.htm?id=<c:out value="${administrator.id}"/>"><c:out value="${administrator.username}"/></a></td>
		<td>
			<c:if test="${administrator.enabled}">
              <fmt:message key="application.yes"/>
			</c:if>
			<c:if test="${!administrator.enabled}">
			  <fmt:message key="application.no"/>	
			</c:if>
		</td>
		<td>
			<a href="administratoredit.htm?id=<c:out value="${administrator.id}"/>"><img src="images/edit.png" alt="<fmt:message key="administrator.edit"/>"/></a>&nbsp;
			<a href="javascript:delete_administrator(<c:out value="${administrator.id}"/>);"><img src="images/delete.png" alt="<fmt:message key="administrator.edit"/>"/></a>
		</td>
	</tr>
</c:forEach>
</table>
<form:form>
<input type="button" align="center" class="btn" onmouseover="this.className='btn btnhov'" onmouseout="this.className='btn'" onclick="document.location='<c:url value="administratoradd.htm"/>'" value="<fmt:message key="administrator.add.heading"/>"/>
</form:form>
